//
//  BJYouXiuDangYuanTableViewCell.m
//  DangXiao
//
//  Created by APPLE on 16/12/7.
//  Copyright © 2016年 APPLE. All rights reserved.
//

#import "BJYouXiuDangYuanCollectionViewCell.h"

@implementation BJYouXiuDangYuanCollectionViewCell
{
    UIImageView *personImageView;
    UILabel *zhiWuLabel;
    UILabel *nameLabel;
    UILabel *danWeiLabel;
}

-(instancetype)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        [self initUI];
    }
    return self;
}

- (void)initUI{
    
    personImageView = [[UIImageView alloc]init];
    personImageView.backgroundColor = BaseColor;
    personImageView.image = [UIImage imageNamed:@"444"];

    [self addSubview:personImageView];
    [personImageView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.mas_equalTo(0);
        make.left.mas_equalTo(0);
        make.right.mas_equalTo(0);
        make.height.mas_equalTo(BILIHEIGHT(220));
    }];
    
    zhiWuLabel = [Utils labelWithTitle:@"一分队队长" titleFontSize:15 textColor:BlackTextColor backgroundColor:ClearColor alignment:0];
    [self addSubview:zhiWuLabel];
    [zhiWuLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(personImageView.mas_bottom).offset(BILIHEIGHT(10));
        make.left.mas_equalTo(0);
    }];
    
    nameLabel = [Utils labelWithTitle:@"刘继平" titleFontSize:15 textColor:BlackTextColor backgroundColor:ClearColor alignment:2];
    [self addSubview:nameLabel];
    [nameLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(personImageView.mas_bottom).offset(BILIHEIGHT(10));
        make.right.mas_equalTo(0);
    }];
    
    danWeiLabel = [Utils labelWithTitle:@"潍坊市高密分局大队" titleFontSize:12 textColor:GrayTextColor backgroundColor:ClearColor alignment:0];
    [self addSubview:danWeiLabel];
    [danWeiLabel mas_makeConstraints:^(MASConstraintMaker *make) {
        make.bottom.mas_equalTo(-BILIHEIGHT(5));
        make.left.mas_equalTo(0);
    }];
}

@end
